package com.fifth.order.mapper;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.fifth.common.pojo.entity.Cart;
import com.fifth.order.vo.GetOrderVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * @作者：刘壬杉
 * @创建时间 2022/9/1 14:20
 **/
@Mapper
public interface CartMapper extends BaseMapper<Cart> {
    /*根据userid查询对应购物车信息*/


    /*根据传入的goodsids数组修改对应商品的state值为1*/
    Integer updateState(List<GetOrderVo> getOrderVos);

    IPage<Cart> findCart(IPage<Cart> page,@Param("ew") QueryWrapper<Cart> queryWrapper);

    void changeCart( List<String> ids,@Param("userid") String userid);
}
